﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Data.SqlClient;

namespace 花店管理系统.geren
{
    public partial class Xiangxixinxi : Form
    {
        public Xiangxixinxi()
        {
            InitializeComponent();
        }

        private void Xiangxixinxi_Load(object sender, EventArgs e)
        {
            DB.GetCn();
            string str = "select * from T_gongao where gongao_id=" + gonggao.Gongaoid + "";
            DataTable dt = DB.GetDataSet(str);

            // 确保dt中有数据
            if (dt.Rows.Count > 0)
            {
                // 使用列名访问数据
                Labiaoti.Text = dt.Rows[0]["biaoti"].ToString();
                richTextBox1.Text = dt.Rows[0]["neirong"].ToString();

                DB.cn.Close();
            }
        }
        

        private void button1_Click(object sender, EventArgs e)
        {
            this.Close();
        }
    }
}
